package com.project.bean;

import java.time.LocalDate;

public class ReplyBean {
    private int id;
    private String content;
    private LocalDate date=LocalDate.now();
    private UserBean user;
    private PrimaryPostBean primary;

    public ReplyBean() {
    }

    public int getId() {
        return id;
    }

    public ReplyBean(String content, int userId, int primaryId) {
        this.content = content;
        this.user=new UserBean();
        this.user.setId(userId);
        this.primary =new PrimaryPostBean();
        this.primary.setId(primaryId);
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public LocalDate getDate() {
        return date;
    }

    public void setDate(LocalDate date) {
        this.date = date;
    }

    public UserBean getUser() {
        return user;
    }

    public void setUser(UserBean user) {
        this.user = user;
    }

    public PrimaryPostBean getPrimary() {
        return primary;
    }

    public void setPrimary(PrimaryPostBean primary) {
        this.primary = primary;
    }

    @Override
    public String toString() {
        return "ReplyBean{" +
                "id=" + id +
                ", content='" + content + '\'' +
                ", date=" + date +
                ", user=" + user +
                ", primary=" + primary +
                '}' + "\n";
    }
}
